<template>
	<view class="sa-nav">
		<image class="sa-nav-icon" src="../static/images/mall/light_1@3x.png" @click="backVc"></image>
		<text class="sa-nav-title">{{title}}</text>
	</view>
</template>

<script>
	export default {
		name: "saNav",
		props: {
			title: {
				type: String,
				default: ""
			}
		},
		methods: {
			backVc() {
				uni.navigateBack({
					delta: 1
				})
			}
		}
	}
</script>

<style scoped lang="scss">
	.sa-nav {
		display: flex;
		align-items: center;
		height: 80rpx;
		position: absolute;
		top: 0;
		width: 100%;
		z-index: 999999;
		&-icon {
			width: 12rpx;
			height: 22rpx;
			margin-left: 20rpx;
		}

		&-title {
			color: #fff;
			text-align: center;
			width: 100%;
		}
	}
</style>
